package com.chat.common.chat.service;

import com.chat.common.chat.domain.vo.request.*;
import com.chat.common.chat.domain.vo.request.member.MemberAddReq;
import com.chat.common.chat.domain.vo.request.member.MemberDelReq;
import com.chat.common.chat.domain.vo.request.member.MemberReq;
import com.chat.common.chat.domain.vo.response.ChatMemberListResp;
import com.chat.common.chat.domain.vo.response.ChatRoomResp;
import com.chat.common.chat.domain.vo.response.MemberResp;
import com.chat.common.common.domain.vo.req.CursorPageBaseReq;
import com.chat.common.common.domain.vo.resp.CursorPageBaseResp;
import com.chat.common.websocket.domain.vo.resp.ws.ChatMemberResp;


import java.util.List;

/**
 * Description:
 * Author: <a href="https://github.com/zongzibinbin">abin</a>
 * Date: 2023-07-22
 */
public interface RoomAppService {
    CursorPageBaseResp<ChatRoomResp> getContactPage(CursorPageBaseReq request, Long uid);

    ChatRoomResp getContactDetail(Long uid, Long roomId);

    ChatRoomResp getContactDetailByFriend(Long uid, Long uid1);

    /**
     * 群组详情
     * @param uid
     * @param roomId
     * @return
     */
    MemberResp getGroupDetail(Long uid, long roomId);

    /**
     * 群成员列表
     * @param request
     * @return
     */
    CursorPageBaseResp<ChatMemberResp> getMemberPage(MemberReq request);

    /**
     * 获取群组下@人员的数组
     * @param request
     * @return
     */
    List<ChatMemberListResp> getMemberList(ChatMessageMemberReq request);

    /**
     * 移除成员
     * @param uid
     * @param request
     */
    void delMember(Long uid, MemberDelReq request);

    /**
     * 新增群组
     * @param uid
     * @param request
     * @return
     */
    Long addGroup(Long uid, GroupAddReq request);

    void addMember(Long uid, MemberAddReq request);
}
